package com.lyd.demo.api.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * 验证参数
 **/
@Setter
@Getter
@ApiModel(value = "ValidParamDto", description = "参数验证DTO")
public class ValidParamDto implements Serializable {

    @ApiModelProperty(value = "业务编码")
    @Size(max = 5, message = "业务编码长度必须在{min}和{max}之间")
    private String business;

    @ApiModelProperty(value = "姓名")
    @NotNull(message = "姓名不能为空")
    private String name;

    @ApiModelProperty(value = "身份证")
    @NotNull(message = "身份证不能为空")
    private String cardId;
}
